<?php
/**
 * Created by PhpStorm.
 * User: s.utkin
 * Date: 05.02.2015
 * Time: 13:41
 */

namespace Jobs;


use Multilang\TranslateEntities;

class UpdateMultilangIndexAction extends \Action {

	protected function run()
	{
		$this->response->noRender(true);
		$this->response->noCache(true);

		/** @var TranslateEntities[] $items */
		$items = TranslateEntities::find()->all();

		foreach ($items as $item) {
			$item->updateAllIndexes();
		}
	}
}